<%@page import="cn.mvcjava.model.User"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
<style>
tr{
 height: 40px;
}
td{
width:80px;
text-align: center;
}
</style>

</head>
<body>
<% User user = (User) request.getAttribute("user"); %>
  <form action="<%= request.getContextPath()%>/updatedo.udo"  >
    <input type="hidden" name="id" value="<%=user.getId()%>"/>
   	  <table style="margin: 20px;padding: 50px;border: 1px solid #000000;">
   	  <% 
   	  String note = (String)request.getAttribute("note");
   	  if(note!=null && "".equals(note)){ %>
   	      <tr>
	          <td style="text-align: left;color:red;font-weight:bolder"><%=note %></td> 
	      </tr>
	      <%
	      }
	      %>
	      <tr>
	          <td style="text-align: left;">用户名：</td>
	          <td style="text-align: right;"><input type="text" name="username"  value="<%=user.getUsername()%>" /></td>
	      </tr>
          <tr>
	          <td style="text-align: left;">密码：</td>
	          <td style="text-align: right;"><input type="text" name="password" value="<%=user.getPassword()%>" /></td>
	      </tr> 
	        
	      <tr>
	          <td style="text-align: left;">地址：</td>
	          <td><input type="text" name="adress" value="<%=user.getAdress()%>"   /></td>
	      </tr>
	       <tr>
	          <td style="text-align: left;">手机号：</td>
	          <td style="text-align: right;"><input type="text" name="phone" value="<%=user.getPhone()%>" /></td>
	      </tr>
	         <tr>  
	          <td colspan="2" style="text-align: right;"><input type="submit"  value="修改表单"  />  
	          </td>
	      </tr>
      </table>
       </form>
</body>
</html>